package com.apex.lottery.service.strategy.execution;


import com.apex.lottery.dao.dataobject.WinningRecordDO;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;

import java.util.List;

/**
 * @ClassName TaskExecutorContext
 * @Description 上下文类
 * @Author ZJX
 * @Date 2025/4/23 19:41
 * @Version 1.0
 **/
public class TaskExecutorContext {

    private final TaskExecutionStrategy taskExecutionStrategy;

    public TaskExecutorContext(TaskExecutionStrategy taskExecutionStrategy) {
        this.taskExecutionStrategy = taskExecutionStrategy;
    }

    public void execute(List<WinningRecordDO> winningRecordDOList) {
        taskExecutionStrategy.execute(winningRecordDOList);
    }

}
